####################################
# Plots gender
####################################

rm(list=ls())

library(Hmisc)
library(ggplot2)
library(stargazer)
library(foreign)
library(gridExtra)

################
# Prepare data 
################

# read data
d = read.csv("~/Dropbox/Gender Chile/08_replication/data_gender.csv")  
d = d[d$Year!=2004,]

#########################
# Plot
#########################

ggplot(d, aes(x = Year, y = Percentage, fill = Group)) + geom_col(position = "dodge") + scale_x_continuous(breaks=c(2004,2008,2012,2016)) +  coord_cartesian(ylim=c(0,1)) + theme_bw() +  scale_fill_manual(name = "Groups",values=c("black", "grey") ) +  theme(legend.key = element_rect(colour = NA)) + theme(text = element_text(size=35)) + theme(legend.position="bottom")

